Re: Free Pascal and Postgresql Functions, Possible? - Mailing list pgsql-general

From Bernd Helmle
Subject Re: Free Pascal and Postgresql Functions, Possible?
Date
Msg-id 5ED593BC2E6FCA1797D01B55@[192.168.100.105]
Whole thread Raw
In response to Re: Free Pascal and Postgresql Functions, Possible?  (Martijn van Oosterhout <kleptog@svana.org>)
Responses Re: Free Pascal and Postgresql Functions, Possible?
List pgsql-general
--On Montag, Dezember 12, 2005 11:16:19 +0100 Martijn van Oosterhout
<kleptog@svana.org> wrote:

> On Sun, Dec 11, 2005 at 10:03:57PM -0600, Tony Caduto wrote:
>> Has there ever been any discussion on
>> using Free Pascal to create functions (C Style)?
>>
>>
>> I know pascal can be used to create user defined functions in other
>> databases like Firebird (which was originally coded in C and now C++)
>

Thought about that some time ago, too...

> Has anyone tried? PostgreSQL doesn't particluarly care what language a
> function was written in, just as long as the calling convention
> matches.
>
> That said, pascal has historically had a different calling convention
> and that is likely to cause the most issues.

Free Pascal offers the cdecl modifier, which allows to declare and access
functions with C style call convention. However, someone needs to write the
necessary interface to the internal PostgreSQL structures that are needed
for UDFs.

>
> Have a nice day,

dito

--
  Thanks

                    Bernd


pgsql-general by date:

Previous
From: CSN
Date:
Subject: Negative offsets
Next
From: "Prakash Nair"
Date:
Subject: postgreSQL 8.0.4 - Windows driver